package day0114;

import java.util.Scanner;

public class Test4 {
    public static void main(String[] args) {
        int num1=50;//生成  //50
        int num2=-1;//输入
        Scanner s=new Scanner(System.in);
        do{
            //输入
            System.out.println("请输入一个数");
            num2=s.nextInt();//50
            //判断大小
            if(num2<num1){
                System.out.println("猜小了");
            }else if(num2>num1){
                System.out.println("猜大了");
            }/*else{
                System.out.println("恭喜你猜对了");
                break;
            }*/
        //}while(true);
        }while(num1!=num2);
        System.out.println("恭喜你猜对了");
    }
}







